package com.demo.mapper;

import com.demo.entity.BOTest;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
// @Repository
public interface TestMapper {

    @Insert("insert into t_test(id,name) values(#{id},#{name})")
    int save(BOTest test);

    @Select("select id,name from t_test")
    List<BOTest> queryAll();
}
